﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace TibcoQueueMonitor.TibcoAdminManagers
{
    /// <summary>
    /// A set of fields that represent parsing metadata of a particular column.
    /// </summary>
    internal struct ColumnOffset
    {
        #region Fields
        /// <summary>
        /// The name of the column.
        /// </summary>
        public string ColumnName;
        /// <summary>
        /// The left-most character position of the column.
        /// </summary>
        public int Position;
        /// <summary>
        /// The length of the column.
        /// </summary>
        public int ColumnLength;
        /// <summary>
        /// Indicates that the column header label is right-justified.
        /// </summary>
        public bool IsRightJustified;

        #endregion Fields

        #region Constructors
        /// <summary>
        /// Initializes a new instance of the <see cref="ColumnOffset"/> struct.
        /// </summary>
        /// <param name="name">The name.</param>
        /// <param name="columnPosition">The column position.</param>
        /// <param name="length">The length.</param>
        /// <param name="rightJustifiedHeader">if set to <c>true</c> indicates
        /// that the column header label is right-justified.</param>
        public ColumnOffset(string name, int columnPosition, int length, bool rightJustifiedHeader)
        {
            ColumnName = name;
            Position = columnPosition;
            ColumnLength = length;
            IsRightJustified = rightJustifiedHeader;
        }

        #endregion //Constructors
    }
}
